<?php
/**
 * 修改表的吞吐量
 * author: JiangJun
 * CreateTime:2021/7/26 23:04
 */

require '../vendor/autoload.php';

use Aws\DynamoDb\Exception\DynamoDbException;
use Aws\DynamoDb\Marshaler;

$sdk = new Aws\Sdk([
    'region'  => 'us-west-2',
    'version' => 'latest'
]);

$dynamodb = $sdk->createDynamoDb();

$result = $dynamodb->updateTable([
    'ProvisionedThroughput' => [ // REQUIRED
        'ReadCapacityUnits'  => 5, // REQUIRED
        'WriteCapacityUnits' => 2, // REQUIRED
    ],
    'TableName'             => 'Movies', // REQUIRED
]);

print_r($result);